<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        div{
            width:100px;
            height:100px;
            background-color: rgba(160, 234, 234, 0.655);
            /* 设置圆角边框 */
            border-radius: 50%;
            /* 2.将动画设置给div */
            animation-name: move;
            /* 时长 */
            animation-duration: 2s;
            /*速度曲线 */
            animation-timing-function: linear;
            /* 设置动画执行次数 */
            animation-iteration-count:infinite;
            /* 动画反向执行 */
            animation-direction: alternate;
        }
        /* 1.定义一个动画关键帧 */
        @keyframes move{
            /* 开始 结束from to */
            /* 需要中间过程0% 25% 50% 75% 100% */
            /* from{
                margin-left: 0px;
            }
            to{
                margin-left: 200px;
            } */
             0%{
                transform: translateX(0px) rotate(0deg);
             }
             25%{
                 transform: translateX(50px) rotate(90deg);
                 border-radius: 10px;
                 background-color: rgba(35, 244, 63, 0.461);
             }
             50%{
                 transform: translateX(100px) rotate(180deg);
                 border-radius: 20px;
                 background-color: rgba(107, 199, 230, 0.461);
             }
             75%{
                 transform: translateX(150px) rotate(270deg);
                 border-radius: 30px;
                 background-color: rgba(35, 38, 244, 0.461);
             }
             100%{
                 transform: translateX(200px) rotate(360deg);
                 border-radius: 40px;
                 background-color: rgba(187, 68, 241, 0.461);
             }
            }
             /* 定义一个心跳的动画 */
             @keyframes  pound{
                form{
                    transform:none;
                }
                to{
                    transform: scale(1.2);
                }
             }
             img{
                animation: pound .2s linear infinite alternate;
             }
        
    </style>
</head>
<body>
    <div></div>
    <img width="50px" src="../音视频/1.webp" alt="">
</body>
</html>